<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8"/>
        <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
        <meta http-equiv="X-UA-Compatible" content="ie=edge"/>
        <title>Document</title>
        <script src = 'jquery-1.10.1.min.js'></script>
        <script>
            window.onload = function(){
                // $("li:eq(2)").css("backgroundColor", 'red');
                // $("li").eq(2).css("backgroundColor", 'red');

                // $("li.box").css("backgroundColor", 'blue');

                $("li").filter(".box").css("backgroundColor", 'yellow');
            }
        </script>
    </head>
    <body>
        <ul>
            <li>1111</li>
            <li class = 'box'>1111</li>
            <li>1111</li>
            <li class = 'box'>1111</li>
            <li>1111</li>
        </ul>
        <span title = 'name'>span</span>
        <div title = 'name'>div</div>
        <p>p</p>
    </body>
</html>